$(function(){
	$("#submit").click(function(){
		var name = $("#name").val();
		var psd = $("#password").val();
		var num = $("#num").val();
		if(name==""){
			layer.open({
				type:0,
				time:1,
				content:'用户名不能为空！',
				skin:'msg',
				shade:'ture',
				anim:'false'
			});
			return false;
		};
		var nameTel = /^1[3|4|5|8][0-9]\d{4,8}$/;
		var nameEmail =  /^([a-zA-Z0-9_-])+@([a-zA-Z0-9_-])+(.[a-zA-Z0-9_-])+/;
		if(!(nameTel.test(name))){
			console.log("111")
			layer.open({
				type:0,
				time:1,
				content:'请填写正确格式！',
				skin:'msg',
				shade:'ture',
				anim:'false'
			});
			return false;
		}
		if(num==""){
			layer.open({
				type:0,
				time:1,
				content:'验证码不能为空！',
				skin:'msg',
				shade:'ture',
				anim:'false'
			});
			return false;
		};
	});
});